﻿package Classes.Weapons.Rockets{
	import flash.display.Sprite;
	import Classes.Utils.*;
	import Classes.Elements.Element;
	import Classes.Sounds.GameSound;
	
	public class Sidewinder extends Rocket{
		
		public function Sidewinder(){
			execution = 8;
			crtspeed = 4;
			speed = -12;
			acceleration = -1;
			omega = 15;
			GameSound.SidewinderLaunch.play();
		}
		override protected function move():void{
			if(Math.abs(crtspeed)<Math.abs(speed)){
				crtspeed += acceleration;
				Moving.moveBeeline(this,crtspeed,this.rotation);
			}						
			else{
				Moving.Track(aTargets[0],this,-crtspeed,omega,-1);
			}
		}		
	}
}